home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="UTF-8"?>
- <!--For basic HTML rendering of QuickView
- -->
- <xsl:stylesheet version="1.0"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <xsl:output method="html" omit-xml-declaration="yes" encoding="UTF-8" />
-
- <xsl:template match="/">
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
- </head>
-
- <body>
- <xsl:for-each select="OpenContactsStandardImport/Sections/Section">
- <div style="margin-left: 15px;">
-
-
- <b>
- <font face="Times New Roman" size="2">
- <xsl:value-of select="@Name"/>
- </font>
- </b>
- </div>
-
-
-
- <table border="0" width="100%" id="table1" cellspacing="0" cellpadding="0">
- <xsl:for-each select="Fields/Field">
- <tr>
- <td width="15"></td>
- <td width="80" bgcolor="#C3D9FF">
- <font face="Times New Roman" size="2">
- <xsl:value-of select="@Name"/>:
- </font>
- </td>
- <td bgcolor="#E0ECFF">
- <font size="3">
- <xsl:value-of select="@Value"/>
- </font>
- </td>
- </tr>
- </xsl:for-each>
-
- </table>
-
- <div style="margin-left: 15px;">
-
- <font size="2" color="#800000">
- <xsl:apply-templates select="Notes"/>
- </font>
-
-
- </div>
-
- </xsl:for-each>
-
- <p> </p>
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="Notes">
- <xsl:call-template name="substitute">
- <xsl:with-param name="string" select="." />
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template name="substitute">
- <xsl:param name="string" />
- <xsl:param name="from" select="'
'" />
- <xsl:param name="to">
- <p/>
- </xsl:param>
- <xsl:choose>
- <xsl:when test="contains($string, $from)">
- <xsl:value-of select="substring-before($string, $from)" />
- <xsl:copy-of select="$to" />
- <xsl:call-template name="substitute">
- <xsl:with-param name="string"
- select="substring-after($string, $from)" />
- <xsl:with-param name="from" select="$from" />
- <xsl:with-param name="to" select="$to" />
- </xsl:call-template>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$string" />
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
- </xsl:stylesheet>